package main

import (
	_ "hello/routers" // _ 表示只执行包里面的init()函数
	"github.com/astaxie/beego"
)

func main() {
	//配置修改
	beego.BConfig.AppName = "beego"
	beego.BConfig.ServerName = "beego-top"//响应头中的server信息
	beego.BConfig.EnableErrorsShow = true //显示错误详情
	beego.BConfig.Listen.EnableAdmin = true //启用内置监控模块

	//session相关设置
	beego.BConfig.WebConfig.Session.SessionOn = true //开启session
	beego.BConfig.WebConfig.Session.SessionProvider = "file"
	beego.BConfig.WebConfig.Session.SessionProviderConfig = "./tmp"

	beego.Run() //启动监听
}
